//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop

#include "UnitConnection.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TFormConnection *FormConnection;
//---------------------------------------------------------------------------
__fastcall TFormConnection::TFormConnection(TComponent* Owner)
        : TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TFormConnection::ButtonConnClick(TObject *Sender)
{
  SQLConnectionOracle->Params->Values["Database"]=EditDB->Text;
  SQLConnectionOracle->Params->Values["User_name"]=EditUserName->Text;
  SQLConnectionOracle->Params->Values["Password"]=EditPassword->Text;

  SQLConnectionOracle->Connected=true;
  SQLConnectionOracle->LoadParamsOnConnect=true;
}
//---------------------------------------------------------------------------

void __fastcall TFormConnection::SQLConnectionOracleAfterConnect(
      TObject *Sender)
{
        FormConnection->Hide();
        MessageBox(NULL,"Connection ok!","Connection",MB_OK);
}
//---------------------------------------------------------------------------

void __fastcall TFormConnection::Button1Click(TObject *Sender)
{
         FormConnection->Hide();
}
//---------------------------------------------------------------------------

